CROSS_PREFIX = riscv64-unknown-elf-

CC = $(CROSS_PREFIX)gcc
OL = 0
CFLAGS = -Wall -S -O$(OL) -fno-builtin

SRC_EXPR = $(wildcard ./*.c)
ASM_EXPR = $(patsubst %.c, %.s, $(SRC_EXPR))
#ASM_EXPR_O2 = $(patsubst %.c, %-O2.s., $(SRC_EXPR))


expr: $(ASM_EXPR)

%.s : %.c
	$(CC) $(CFLAGS) $< -o $@